package com.zzy.ymcc.dto;

import com.zzy.utils.AssertUtil;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class PhoneRegisterDto {


    @Pattern(regexp = AssertUtil.PHONE_FORMAT, message = "手机号格式不正确！")
    private String mobile;

    @Size(min = 6, max = 12, message = "密码必须在6到12位之间！")
    private String password;

    @NotNull
    private String smsCode;

    @NotNull
    private Integer regChannel;
}
